const readline = require("readline")
const r1 = readline.createInterface
({
    input:process.stdin,
    output:process.stdout,
})

let input_arr = []
r1.on('line',function(line)
{
    input_arr.push(line)
})

r1.on('close',function()
{
let input = `9
88 74 101 26 15 0 34 22 77`
let input_arr = input.split('\n')

//解题代码
// let num = parseInt(input_arr[0])
let num = input_arr[1].split(' ')
let odd_count = 0
for(let i = 0;i < num.length;i++)
    {
        if(num[i]%2 === 1)
        {
            odd_count++
        }
    }
let even_count = num.length - odd_count//num需要指出来长度，长度才是数的总数
console.log(`${odd_count} ${even_count}`)
})